// projectile.h

#ifndef PROJECTILE_H
#define PROJECTILE_H

#include <QWidget>
#include <QImage>
#include <QColor>
#include <QPoint>
#include <QPainter>
#include "drawarea.h"
#include "test.h"


class projectile
{
public:
    projectile();
    enum type {balls, watermelon, balloon};
    virtual void drawprojectile(QPainter &painter) = 0;
    virtual type getballtype() = 0;
    QPoint ReturnCenterPoint() { return centerpoint; }
    int ReturnRadius() { return radius; }
    void SetBallType(type typeofball) { balltype = typeofball; }
    void SetCenterPoint(QPoint CP) { centerpoint = CP; }
    void SetRadius(int R) { radius = R; }
    void SetCoordConverter(coordconv xcc) { CoordConverter = xcc;}

    type balltype;
    coordconv CoordConverter;

private:
    QPoint centerpoint;
    int radius;
};


class ball : public projectile
{
public:
    ball();
    void drawprojectile(QPainter &painter);
    type getballtype() { return balls; }

};

#endif // PROJECTILE_H
